package com.xm.service.framework.feign.fallback;


import com.xm.service.framework.feign.BookFeignClient;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.RequestParam;
import xm.common.book.entity.Book;

import java.util.Collections;
import java.util.HashMap;
import java.util.List;
import java.util.Map;


public class BookFeignClientFallback implements BookFeignClient {

    @Override
    public List<Book> list() {
        return Collections.emptyList();
    }

    @Override
    public String  add(@RequestParam String author, @RequestParam int stock,
                       @RequestParam String name, @RequestParam String date) {
        return "添加图书失败";
    }

    @Override
    public String updateStockByid(int id, int stock) {
        return "BookFeignClientFallback";
    }

    @Override
    public String deleteById(int id) {
        return "BookFeignClientFallback";
    }

}
